package cn.seaboot.admin.quartz.bean;

import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.v3.oas.annotations.media.Schema;

import javax.validation.constraints.Size;
import java.io.Serializable;
import java.time.LocalDateTime;

/**
 * POJO
 * 计划任务日志明细 [t_schedule_item]
 * @author Mr.css on 2018-6-20
 */
@Schema(description = "计划任务日志明细 [t_schedule_item] 实体类")
public class ScheduleItem implements Serializable {

    private static final long serialVersionUID = 8891618091903381810L;
    /**
     * ID
     */
    @Schema(description = "ID")
    @JsonFormat(shape = JsonFormat.Shape.STRING)
    private Long id;
    /**
     * 结束时间
     */
    @Schema(description = "结束时间")
    private LocalDateTime gmtEnd;
    /**
     * 创建日期
     */
    @Schema(description = "创建日期")
    private LocalDateTime gmtCreate;
    /**
     * 任务批次
     */
    @Schema(description = "任务批次")
    private Long logId;
    /**
     * 日志类型
     */
    @Schema(description = "日志类型")
    private Integer logType;
    /**
     * 日志等级
     */
    @Schema(description = "日志等级")
    private Integer logLevel;
    /**
     * 业务唯一标识
     */
    @Size(max = 32)
    @Schema(description = "业务唯一标识")
    private String eventId;
    /**
     * 业务唯一标识
     */
    @Size(max = 32)
    @Schema(description = "业务名称")
    private String eventName;
    /**
     * 状态
     */
    @Schema(description = "业务状态")
    private Integer eventStatus;
    /**
     * 简短的数据信息
     */
    @Size(max = 126)
    @Schema(description = "简短的数据信息")
    private String eventData;
    /**
     * 错误数
     */
    @Schema(description = "受影响行数")
    private Integer effectRows;
    /**
     * 简短的错误描述
     */
    @Schema(description = "简短的错误描述")
    private String description;
    /**
     * 开始时间
     */
    @Schema(description = "开始时间")
    private LocalDateTime gmtStart;

    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    public LocalDateTime getGmtEnd() {
        return gmtEnd;
    }

    public void setGmtEnd(LocalDateTime gmtEnd) {
        this.gmtEnd = gmtEnd;
    }

    public LocalDateTime getGmtCreate() {
        return gmtCreate;
    }

    public void setGmtCreate(LocalDateTime gmtCreate) {
        this.gmtCreate = gmtCreate;
    }

    public Long getLogId() {
        return logId;
    }

    public void setLogId(Long logId) {
        this.logId = logId;
    }

    public Integer getLogType() {
        return logType;
    }

    public void setLogType(Integer logType) {
        this.logType = logType;
    }

    public Integer getLogLevel() {
        return logLevel;
    }

    public void setLogLevel(Integer logLevel) {
        this.logLevel = logLevel;
    }

    public String getEventId() {
        return eventId;
    }

    public void setEventId(String eventId) {
        this.eventId = eventId;
    }

    public String getEventName() {
        return eventName;
    }

    public void setEventName(String eventName) {
        this.eventName = eventName;
    }

    public Integer getEventStatus() {
        return eventStatus;
    }

    public void setEventStatus(Integer eventStatus) {
        this.eventStatus = eventStatus;
    }

    public String getEventData() {
        return eventData;
    }

    public void setEventData(String eventData) {
        this.eventData = eventData;
    }

    public Integer getEffectRows() {
        return effectRows;
    }

    public void setEffectRows(Integer effectRows) {
        this.effectRows = effectRows;
    }

    public String getDescription() {
        return description;
    }

    public void setDescription(String description) {
        this.description = description;
    }

    public LocalDateTime getGmtStart() {
        return gmtStart;
    }

    public void setGmtStart(LocalDateTime gmtStart) {
        this.gmtStart = gmtStart;
    }

    @Override
    public String toString() {
        return "ScheduleItem{" +
                "id='" + id + '\'' +
                ", gmtEnd=" + gmtEnd +
                ", gmtCreate=" + gmtCreate +
                ", logId='" + logId + '\'' +
                ", logType=" + logType +
                ", logLevel=" + logLevel +
                ", eventId='" + eventId + '\'' +
                ", eventName='" + eventName + '\'' +
                ", eventStatus=" + eventStatus +
                ", eventData='" + eventData + '\'' +
                ", effectRows=" + effectRows +
                ", description='" + description + '\'' +
                ", gmtStart=" + gmtStart +
                '}';
    }
}
